<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* E[att] */
        div[class]{
            background-color: rgb(248, 127, 147);
        }

        /* E[att = "val"] */
        div[id = "Test2"]{
            background-color: skyblue;
        }

        /* E[att^"val"] */
        div[id ^= "tes"]{
            background-color: gold;
        }

        /* E[att$="val"] */
        div[id $= "4"]{
            background-color: red;
        }

        /* E[att*="val"] */
        div[id *= "on"]{
            background-color: green;
        }

        div{
            height:200px;
            margin: 2px;
        }
    </style>
</head>
<body>
    <div class = "Test1"></div>
    <div id = "Test2"></div>
    <div id = "test3"></div>
    <div id = "Test4"></div>
    <div id = "ontest5"></div>
</body>
</html>